﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="region_add.aspx.cs" Inherits="Com.CMS263.Web.manage.ManageRegion.region_add" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>无标题页</title>

    <script src="/manage/js/jquery-1.4.2.min.js"></script>

    <link href="/manage/css/common.css" rel="stylesheet" type="text/css" />
    <link href="/manage/css/main.css" rel="stylesheet" type="text/css" />
    <link href="/manage/css/box.css" rel="stylesheet" type="text/css" />

    <script>
        function check() {
            var reg = new RegExp("^[0-9]*$");
            var name = $("#txtName").val();
            var order = $("#txtOrder").val();
            if (name.length < 1) {
                alert("请输入名称");
                return false;
            }
            if (!reg.test(order) || order.length < 1) {
                alert("排序请输入数字!");
                return false;
            }

            return true;
        }
    </script>

</head>
<body>
    <form id="form1" runat="server" action="" method="post" enctype="multipart/form-data">
    <div class="main">
        <div class="mainMenu">
            <div class="mainMenuList">
                <ul>
                    <li class="s"><a><b>添加区域</b><span></span></a></li>
                    <li><a href="regionlist.aspx"><b>区域列表</b><span></span></a></li>
                </ul>
            </div>
        </div>
        <div class="mainContent">
            <div class="productSearch">
                <table width="100%" border="0" cellspacing="0" cellpadding="0" class="table1">
                    <tr>
                        <td width="160" class="c">
                        </td>
                        <td width="80" class="c">
                            名称
                        </td>
                        <td width="160" class="c">
                            <input type="text" id="txtName" name="txtName" />
                        </td>
                        <td class="c">
                        </td>
                    </tr>
                    <tr>
                        <td width="160" class="c">
                        </td>
                        <td width="80" class="c">
                            排序
                        </td>
                        <td width="160" class="c">
                            <input type="text" id="txtOrder" name="txtOrder" />
                        </td>
                        <td class="l">
                            请输入数字
                        </td>
                    </tr>
                    <tr>
                        <td width="160" class="c">
                        </td>
                        <td width="80" class="c">
                            推荐
                        </td>
                        <td width="160" class="c">
                            <input type="checkbox" value="1" name="chkBest" />
                        </td>
                        <td class="l">
                            非区县级可以推荐
                        </td>
                    </tr>
                    <tr>
                        <td width="160" class="c">
                        </td>
                        <td width="80" class="c">
                            父类
                        </td>
                        <td width="160" class="c">
                            <select name="selFather">
                                <option value="0">区县级</option>
                                <% foreach (var item in list)
                                   {%>
                                <option value="<%=item.Id%>">
                                    <%=item.Name %>
                                </option>
                                <%} %>
                            </select>
                        </td>
                        <td class="c">
                        </td>
                    </tr>
                    <tr>
                        <td colspan="4">
                            <div class="con1 productFormBtn cf">
                            </div>
                        </td>
                    </tr>
                    <tr>
                        <td width="160" class="c">
                        </td>
                        <td width="80" class="c">
                            <asp:Button ID="Button1" OnClientClick="return check()" runat="server" 
                                Text="保存" onclick="Button1_Click" />
                        </td>
                        <td width="160" class="c">
                        </td>
                        <td class="c">
                        </td>
                    </tr>
                </table>
            </div>
        </div>
    </div>
    </form>
</body>
</html>
